#抖音接口直接发送弹幕,难度太高未完成
# import requests
# url = "https://live.douyin.com/webcast/room/chat/"
# data = {
# 'aid':'6383',
# 'app_name':'douyin_web',
# 'live_id':'1',
# 'device_platform':'web',
# 'language':'zh-CN',
# 'enter_from':'web_live',
# 'cookie_enabled':'true',
# 'screen_width':'1707',
# 'screen_height':'960',
# 'browser_language':'zh-CN',
# 'browser_platform':'Win32',
# 'browser_name':'Edge',
# 'browser_version':'138.0.0.0',
# 'room_id':'7523512639729814314', #直播间id
# 'content':'卡牌', #弹幕发送内容
# 'type':'0',
# 'rtf_content':"",
#     #不同
# 'msToken':'SxtFKWzKyBWn4y6mTZEeZUCUWz2_uT9ylTQOkUShJxzIY5kHoJ5nyALd6LxaTr67oDrHz1KUnkyY3x-Fj2DgUqv7LQfiycx2Hgm8Gs3LlzoSgWX1CrMCGf7ByezbCXOJiq78G1HzUMVYOx0AIz7GfNa7PxtrhrZMaAC8uSNo_emVvKP1_E8MVD4=',
#     #不同
# 'a_bogus':'O6URgwSymxRbKdFSuOdiHA2UZofMNT8yoPiobJduHNP3G1UaJ8Nvint0aozpAEtDLRpkkoq76nFlPEVc/xXs1/Hpqskkum4bo0dInWmLhqhVPavh7rWzeitxFk-cW/GOOA53ipLXWzUH19cvZNCMA1FySCen-WY0TqrbdaUlexg5g4iYI9QSe-hv'
# }
# headers = {
#     'User-Agent':"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36 Edg/138.0.0.0",
#     'Referer':"https://live.douyin.com/567523334915?anchor_id=1649737575434268&follow_status=0&is_vs=0&vs_ep_group_id=&vs_episode_id=&vs_episode_stage=&vs_season_id=&web_live_tab_2=&web_live_tab_3=",
#     'Cookie':"UIFID_TEMP=a6000b6bd0597977c28c1dbb751d8a8c80ef4c078dbea6da280536e6f6924b82fb3fde54fa117a4ba07420fc7fa9edc397b783250111554bed47b795da2498a9cee3bcbaf88cbaec9113d38d06281e9c; UIFID=a6000b6bd0597977c28c1dbb751d8a8c80ef4c078dbea6da280536e6f6924b82044e978d25b119d68f1fcd71189d1b628e917f7177d79b3eca28a51bb1c5319e9f02e263dc8474e1c313fb76c8bf39e1d9c94612a4eecbffc6d6499c48d52420e17f0b3ad71ced1a8c80f99d6270fa13f393518084e654213243869711af197783fd2fcc2c2b354d93e80a83b846a9c978c03e681b0bce02a456cb419a4fffe7; hevc_supported=true; passport_csrf_token=6cb616b87a8cb39e7898d6daf44b9871; passport_csrf_token_default=6cb616b87a8cb39e7898d6daf44b9871; __security_mc_1_s_sdk_crypt_sdk=1e56b514-42f2-b734; bd_ticket_guard_client_web_domain=2; SearchMultiColumnLandingAbVer=2; SEARCH_RESULT_LIST_TYPE=%22multi%22; __security_mc_1_s_sdk_sign_data_key_sso=9f35d254-4b7e-8e18; enter_pc_once=1; stream_recommend_feed_params=%22%7B%5C%22cookie_enabled%5C%22%3Atrue%2C%5C%22screen_width%5C%22%3A1707%2C%5C%22screen_height%5C%22%3A960%2C%5C%22browser_online%5C%22%3Atrue%2C%5C%22cpu_core_num%5C%22%3A16%2C%5C%22device_memory%5C%22%3A8%2C%5C%22downlink%5C%22%3A10%2C%5C%22effective_type%5C%22%3A%5C%224g%5C%22%2C%5C%22round_trip_time%5C%22%3A50%7D%22; is_dash_user=1; volume_info=%7B%22isUserMute%22%3Afalse%2C%22isMute%22%3Atrue%2C%22volume%22%3A0.6%7D; home_can_add_dy_2_desktop=%221%22; stream_player_status_params=%22%7B%5C%22is_auto_play%5C%22%3A0%2C%5C%22is_full_screen%5C%22%3A0%2C%5C%22is_full_webscreen%5C%22%3A0%2C%5C%22is_mute%5C%22%3A1%2C%5C%22is_speed%5C%22%3A1%2C%5C%22is_visible%5C%22%3A0%7D%22; x-web-secsdk-uid=ad4c17e7-af04-4e15-934d-a55bdd547c20; has_avx2=null; device_web_cpu_core=16; device_web_memory_size=8; live_use_vvc=%22false%22; csrf_session_id=f3b4805eac65df3f92d1bdcd2dec9257; xgplayer_user_id=854724626023; __ac_nonce=0687171370075ffbea9b2; __ac_signature=_02B4Z6wo00f01d8FVqgAAIDDPMqmPt2VvJ3fJVIAAB-y08; fpk1=U2FsdGVkX1/S2ZEKtvIjYWtanqIbuB0GxcHjl0DKMD9KHv/LYr+GGuYDgd4knG0Nm/qGcmmTZh/2H7yFXT4ZCw==; fpk2=d2ad6785d256851dd366703bdc61aa61; webcast_leading_last_show_time=1752265028738; webcast_leading_total_show_times=1; passport_mfa_token=Cjfwb5IgcXNvvPeVaBrOAc7JD8MVxUWDOp5rJ26Wfc6ImGbfVt51bKwWbAHl3Njoyym%2F0FUPfyhkGkoKPAAAAAAAAAAAAABPOLzKSMDQhC8NS2qIXsj2pRnOTqs1KCiBjE%2BljrWpk1yLHjX5arEfMaaO0bHRcP57%2BhDZvfYNGPax0WwgAiIBA7qxHxY%3D; d_ticket=f45c64778e8708dfc9a06c18ca811863b18ae; passport_assist_user=CkGRydcxGV_sLP5OmzEnbUqtCwnAW6Fqz9jGReq6Mz3DLso4-9s0R4ufaQSO4WRe2I18pEz7_fbvOOlzH4zH0HRRoxpKCjwAAAAAAAAAAAAATzhrD6M_Lug11VcBkTDzIAO2diJ_cxa5Hr4uS8i8J52TGHEQBB4kmawxLQ-9kQ1v-sIQ3b72DRiJr9ZUIAEiAQOc_24X; n_mh=NUfvsSigxCMVEyGZjOE34_ui_uSdeDMV1bGSDmTw4rk; sid_guard=72b2d5d39bdea7763f1e0f4191ebccf7%7C1752265237%7C5184000%7CTue%2C+09-Sep-2025+20%3A20%3A37+GMT; uid_tt=b9b1d415be68cc1ba50a45149e86c309; uid_tt_ss=b9b1d415be68cc1ba50a45149e86c309; sid_tt=72b2d5d39bdea7763f1e0f4191ebccf7; sessionid=72b2d5d39bdea7763f1e0f4191ebccf7; sessionid_ss=72b2d5d39bdea7763f1e0f4191ebccf7; session_tlb_tag=sttt%7C16%7CcrLV05vep3Y_Hg9BkevM9__________0t6kRYE-RK9RWJup5sfTW-7qSkZjLWahdiBmKb76eF8o%3D; is_staff_user=false; sid_ucp_v1=1.0.0-KDMwY2ZhZGE1OGEwMGY3Mzc4NWQ2OTJiYzI1YmRlOGQzN2Y5Njc3OGUKIQiUk9Dg0czGBRCV5MXDBhjvMSAMMNGDx6oGOAdA9AdIBBoCaGwiIDcyYjJkNWQzOWJkZWE3NzYzZjFlMGY0MTkxZWJjY2Y3; ssid_ucp_v1=1.0.0-KDMwY2ZhZGE1OGEwMGY3Mzc4NWQ2OTJiYzI1YmRlOGQzN2Y5Njc3OGUKIQiUk9Dg0czGBRCV5MXDBhjvMSAMMNGDx6oGOAdA9AdIBBoCaGwiIDcyYjJkNWQzOWJkZWE3NzYzZjFlMGY0MTkxZWJjY2Y3; login_time=1752265237470; _bd_ticket_crypt_cookie=41b93986de5ce700fc9bed84a9d0a5b9; __security_mc_1_s_sdk_sign_data_key_web_protect=ccf7982f-440c-bd07; __security_mc_1_s_sdk_cert_key=7d0e025c-4aad-b7b5; __security_server_data_status=1; SelfTabRedDotControl=%5B%5D; publish_badge_show_info=%220%2C0%2C0%2C1752265252406%22; WallpaperGuide=%7B%22showTime%22%3A1752265262191%2C%22closeTime%22%3A0%2C%22showCount%22%3A1%2C%22cursor1%22%3A10%2C%22cursor2%22%3A2%7D; xg_device_score=7.694897303211912; download_guide=%223%2F20250712%2F0%22; h265ErrorNum=-1; __live_version__=%221.1.3.5791%22; webcast_local_quality=ld; IsDouyinActive=true; bd_ticket_guard_client_data=eyJiZC10aWNrZXQtZ3VhcmQtdmVyc2lvbiI6MiwiYmQtdGlja2V0LWd1YXJkLWl0ZXJhdGlvbi12ZXJzaW9uIjoxLCJiZC10aWNrZXQtZ3VhcmQtcmVlLXB1YmxpYy1rZXkiOiJCQjlIL1FZRjkwa2xKVTFOdk9iQml4Z1dCamU5dXdGYWZOQUUwRGhQQlUxOHl2d0pPanIzV2lDc1JzYzVOeU9jcXBobHJCWC9BTmdZcnF1MzExMWx3cms9IiwiYmQtdGlja2V0LWd1YXJkLXdlYi12ZXJzaW9uIjoyfQ%3D%3D; live_can_add_dy_2_desktop=%221%22; passport_fe_beating_status=true; biz_trace_id=7c602bea; sdk_source_info=7e276470716a68645a606960273f276364697660272927676c715a6d6069756077273f2771777060272927666d776a68605a607d71606b766c6a6b5a7666776c7571273f275e58272927666a6b766a69605a696c6061273f27636469766027292762696a6764695a7364776c6467696076273f275e5827292771273f27303532363333303337373032342778; bit_env=vRFsAOs-FgPIJk6xFDSt3qyP9NfA2QwTpEh2y6NHwKq3raAsqMJQAs2mK3efPxljnYGkpy3Yx757-oEPG_6EGtpXRRBqtW7_MMHsGj15WOAfGjWx0n7qJJCF6_o6hDzAJ98l6hceInLhBT8nbXgz3pRx0JfdUQgrQO1HoDUXY8ElRL6W7UT1li_5fGgBV8YKAjlkCYU9c-suLSRQ-fmJQSycdNZbXSWQRioL6E1DFSG4d6G1wb7Lled5T6qz439WQwTK1CKBTwqxFzElC0WE2H56D6laMhiXkVy2Xgd5C0c053MJsUNFICcDqAyxn3C_sMSJuxV_n79hV8-wnBSCdG1dnankT-aMYfGMCaSh3PoSrqAG-z-i3YKbK9zWQ6v-n15aCrtG0pWQT-rEaj547qBRTPn-Z8X7xbHLloQd4CZn1MZm9W1E47yfMxn0we0eOV7SoXqAg9az6PgMsR18HKjNA4XE5RgOQO1WI2I91Xg5Afu7aBAWFG4my9MCRZD15RP3DfnYGz9JJ_xc0k1oRCH0_Lh6oX8qGMdA048FuvQ%3D; gulu_source_res=eyJwX2luIjoiNzU0M2ZjOGQ1M2I0ODllM2QzNDA1NDBmYmViY2VhOTQ5YjdkNmE0NmQyY2RiODQzN2RiNDY4OTdiNDkzN2RlZiJ9; passport_auth_mix_state=k751g17u1u9tpulxd5l2hixres35338nsgilg9gmv9sxg0k6; ttwid=1%7CqQmnR9ZZ5nnxAQ23tMq6VgZzlJDFMu_YjJY3XqvLN5w%7C1752265667%7C1d2931e03dc954d85b04cd89fef10dc9c2d72652605b3f63b39fa49f9de402cf; odin_tt=8568e59dea7718e1ef041016f03e45680128835c58fa02f909cbdae514c8ef1ad38e773e9284d96c12b665447e01659ca7ee21bfcef56144e7a405759a6ec943"
# }
# res = requests.post(url,headers=headers,data=data)
# print(res.text)
